<?php
	require('config.php');
	$user_id = $_REQUEST['user_id'];
	$business_license_thumb = $_REQUEST['business_license_thumb'];
	$card_thumb = $_REQUEST['card_thumb'];
	$card_thumb2 = $_REQUEST['card_thumb2'];
	$card_thumb3 = $_REQUEST['card_thumb3'];
	$urlInfo1 = explode('com', $business_license_thumb);
	$urlInfo2 = explode('com', $card_thumb);
	$urlInfo3 = explode('com', $card_thumb2);
	$urlInfo4 = explode('com', $card_thumb3);
	// 营业执照
	$businessLicenseUrl = $urlInfo1[1];
	// 手持身份证照
	$handIdCardUrl = $urlInfo2[1];
	// 正面
	$idCardFrontUrl = $urlInfo3[1];
	// 反面
	$idCardVersoUrl = $urlInfo4[1];
	// 更新用户资料
	$sql = "update " . $oto . "_users set businessLicenseUrl='{$businessLicenseUrl}',handIdCardUrl='{$handIdCardUrl}',idCardFrontUrl='{$idCardFrontUrl}',idCardVersoUrl='{$idCardVersoUrl}',isAudit='2' where userId='{$user_id}'";
	$result = $db->query($sql);
	if ($result) {
    	$data['status'] = 'success';
	} else {
	    $data['status'] = 'false';
	}
	echo json_encode($data);

?>